<?php

namespace app\http\middleware;

use app\common\auto\AutoValidate;
use app\common\auto\SystemConst;

class Before
{
    public function handle($request, \Closure $next)
    {
        // 注册系统常量
        app(SystemConst::class)->initialize();
        // 注册自动验证类
        app(AutoValidate::class)->initialize();
        return $next($request);
    }
}
